//匹配规则
const notInclude = ['id']


//比较对象的差异属性并剔除,用于更新操作剔除没有被修改的类
export function equalsObject(a, b) {
    let aProps = Object.getOwnPropertyNames(a);
    for (let i = 0; i < aProps.length; i++) {
        let propName = aProps[i];
        if (a[propName] === b[propName] && !notInclude.includes(propName)) {
            Reflect.deleteProperty(a, propName)
        }
    }
    return a
}
